function Person(name){
    this.name=name
}
Person.prototype.getName=function(){
    return this.name
}

var myNew=function(){
    let newObj= Object.create(null)//[[Prototype]]链为空 所以后面 Object.getPrototypeOf(a)===Person.prototype为false
    let F=[].shift.call(arguments)
    newObj.__proto__=F.prototype
    let ret = F.call(newObj,...arguments)
    return typeof ret==='object' ? ret : newObj
}
let a = myNew(Person,'dyx')
console.log(a.name);
console.log(Object.getPrototypeOf(a)===Person.prototype);//false
console.log(a.__proto__===Person.prototype);//true
